package com.wasai.domain;

import java.sql.Timestamp;
import java.util.Set;

import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.FetchType;
import javax.persistence.MappedSuperclass;
import javax.persistence.OneToMany;

@MappedSuperclass
public class AbstractPromotion extends BaseDomain {
	/**
	 * 
	 */
	private static final long serialVersionUID = -8923956390524906483L;
	private Set<Comment> comments;
	private String description;
	private String img;
	private String orgPrice;
	private String proPrice;
	private String source;
	private String title;
	private String url;
	private Timestamp validDate;

	@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "promotion")
	public Set<Comment> getComments() {
		return comments;
	}

	@Column(name = "description", length = 5000)
	public String getDescription() {
		return description;
	}

	@Column(name = "img", length = 500)
	public String getImg() {
		return img;
	}

	@Column(name = "org_price", length = 50)
	public String getOrgPrice() {
		return orgPrice;
	}

	@Column(name = "pro_price", length = 50)
	public String getProPrice() {
		return proPrice;
	}

	@Column(name = "source", length = 50)
	public String getSource() {
		return this.source;
	}

	@Column(name = "title", length = 500)
	public String getTitle() {
		return title;
	}

	@Column(name = "url", length = 500)
	public String getUrl() {
		return url;
	}

	@Column(name = "valid_date")
	public Timestamp getValidDate() {
		return validDate;
	}

	public void setComments(Set<Comment> comments) {
		this.comments = comments;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public void setImg(String img) {
		this.img = img;
	}

	public void setOrgPrice(String orgPrice) {
		this.orgPrice = orgPrice;
	}

	public void setProPrice(String proPrice) {
		this.proPrice = proPrice;
	}

	public void setSource(String source) {
		this.source = source;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public void setValidDate(Timestamp validDate) {
		this.validDate = validDate;
	}
}
